{#
/*
 * This file is part of the ProductReview plugin
 *
 * Copyright (C) 2016 LOCKON CO.,LTD. All Rights Reserved.
 *
 * For the full copyright and license information, please view the LICENSE
 * file that was distributed with this source code.
 */
#}
{#
[商品管理]-[商品レビュー]-[編集]画面
#}

{% extends '@admin/default_frame.twig' %}

{% set menus = ['store', 'plugin', 'plugin_list'] %}

{% block title %}{{ 'product_review.admin.config.title'|trans }}{% endblock %}
{% block sub_title %}{{ 'product_review.admin.config.sub_title'|trans }}{% endblock %}

{% form_theme form '@admin/Form/bootstrap_4_horizontal_layout.html.twig' %}

{% block main %}

    <form method="post" action="{{ url('product_review_replyable_admin_config') }}">
        {{ form_widget(form._token) }}
        <div class="c-contentsArea__cols">
            <div class="c-contentsArea__primaryCol">
                <div class="c-primaryCol">
                    <div class="card rounded border-0 mb-4">
                        <div class="card-header">
                            <div class="row">
                                <div class="col-8">
                                    <div class="d-inline-block" data-toggle="tooltip" data-placement="top"
                                         title="Tooltip">
                                        <span class="card-title">{{ 'product_review.admin.config.config_title'|trans }}</span>
                                    </div>
                                </div>
                                <div class="col-4 text-right">
                                    <a data-toggle="collapse" href="#basicConfig" aria-expanded="false"
                                       aria-controls="basicConfig">
                                        <i class="fa fa-angle-up fa-lg"></i>
                                    </a>
                                </div>
                            </div>
                        </div>

                        <div class="collapse show ec-cardCollapse" id="basicConfig">
                            <div class="card-body">
                                <div class="row mb-2">
                                    <div class="col-3">
                                        <label>{{ 'product_review.admin.config.review_max'|trans({
                                                '%min%': eccube_config.product_review_display_count_min,
                                                '%max%': eccube_config.product_review_display_count_max,
                                            }) }}</label>
                                    </div>
                                    <div class="col">
                                        {{ form_widget(form.review_max) }}
                                        {{ form_errors(form.review_max) }}
                                    </div>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </div>

        <div class="c-conversionArea">
            <div class="c-conversionArea__container">
                <div class="row justify-content-between align-items-center">
                    <div class="col-6">
                        <div class="c-conversionArea__leftBlockItem">
                            <a class="c-baseLink" href="{{ url('admin_store_plugin') }}"><i class="fa fa-backward" aria-hidden="true"></i>
                                <span>{{ 'product_review.admin.config.conversion.back'|trans }}</span></a>
                        </div>
                    </div>
                    <div class="col-6">
                        <div class="row align-items-center justify-content-end">
                            <div class="col-auto">
                                <button class="btn btn-ec-conversion px-5" type="submit">{{ 'product_review.admin.config.conversion.save'|trans }}</button>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </form>

{% endblock %}
